let http =require("http")
let port =3000
let hostname = "0.0.0.0"

http.createServer((req,res)=>{
console.log(req.url);
res.writeHead(200,{'content-Type':'text/html;charset=utf8'})
res.write("<h2>无法访问此网站</h2>")
res.write("<h2>localhost 拒绝了我们的连接请求</h2>")
res.write("<h2>请试试以下办法</h2>")
res.write("<h2>检查网络连接</h2>")
res.write("<h2>检查代理服务器和防火墙</h2>")
res.write("<h2>你流弊</h2>")
res.end()

}).listen(port,hostname,()=>{
    console.log(`this server is running at http://${hostname}:${port}`)
})